module substitution(sub_in,sub_out); 
/*每四位进行S-box替换*/

input  wire [63:0] sub_in;
output wire [63:0] sub_out;

genvar j;
generate
    for (j = 0; j < 16; j = j+1)
    begin : boxes
        s_box substitution_sbox (.sbox_out(sub_out[j*4+3:j*4]),.sbox_in(sub_in[j*4+3:j*4]));    
    end
endgenerate


endmodule